﻿using OpenCvSharp;
using System;
using System.IO;


// Load an image from file
using Mat image = Cv2.ImRead(@"../pic/horse.png");
// Check if the image is loaded successfully
if (image.Empty())
{
    Console.WriteLine("Could not load image.");
    return;
}
// Display the image in a window
Cv2.ImShow("Image", image);
Cv2.WaitKey(0); // Wait for a key press
                // Release resources
Cv2.DestroyAllWindows();
